﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Register.ascx.cs" Inherits="Pages_Register" %>
<%@ Register assembly="DevExpress.Web.ASPxEditors.v11.2, Version=11.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxEditors" tagprefix="dx" %>

<%@ Register assembly="DevExpress.Web.v11.2, Version=11.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxLoadingPanel" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v11.2, Version=11.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxCallback" tagprefix="dx" %>

<style type="text/css">
    .styleRegister
    {
        width: 124px;
    }
    .styleRegister2
    {
        width: 40px;
    }
    .styleRegister3
    {
        width: 20px;
    }    
</style>


<asp:MultiView ID="MultiView1" runat="server">
    <asp:View ID="View1" runat="server">
        <table style="width:100%;">
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLoadingPanel ID="LoadingPanel" runat="server" 
                        ClientInstanceName="LoadingPanel" Modal="True" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        ImageSpacing="5px">
                        <Image Url="~/App_Themes/DevEx/Web/Loading.gif">
                        </Image>
                    </dx:ASPxLoadingPanel>
                    <dx:ASPxCallback ID="ASPxCallback1" runat="server" 
                        ClientInstanceName="Callback">
                        <ClientSideEvents CallbackComplete="function(s, e) { LoadingPanel.Hide(); }" />
                    </dx:ASPxCallback>
                    <br />
                </td>
                <td>
                    <asp:ValidationSummary ID="ValidationSummary1" runat="server" TabIndex="10" />
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel5" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Full name:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <dx:ASPxTextBox ID="txtFullName" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="1" 
                        Width="170px">
                    </dx:ASPxTextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                        ControlToValidate="txtFullName" Display="None" 
                        ErrorMessage="Full name is not blank!" SetFocusOnError="True"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel1" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Username:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <dx:ASPxTextBox ID="txtUser" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="1" 
                        Width="170px">
                    </dx:ASPxTextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                        ControlToValidate="txtUser" Display="None" 
                        ErrorMessage="Username is not blank!" SetFocusOnError="True"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
                        ControlToValidate="txtUser" Display="None" 
                        ErrorMessage="Username must be at least 6 to 30 characters!" 
                        SetFocusOnError="True" ValidationExpression="[0-9a-zA-Z]{6,30}"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel2" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Password">
                    </dx:ASPxLabel>
                    :</td>
                <td>
                    <dx:ASPxTextBox ID="txtPass" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Password="True" SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" 
                        TabIndex="2" Width="170px">
                    </dx:ASPxTextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                        ControlToValidate="txtPass" Display="None" 
                        ErrorMessage="Password is not blank!" SetFocusOnError="True"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" 
                        ControlToValidate="txtPass" Display="None" 
                        ErrorMessage="Password must be at least 6 to 30 characters!" 
                        SetFocusOnError="True" ValidationExpression="[0-9a-zA-Z]{6,30}"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel3" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Comfirm password:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <dx:ASPxTextBox ID="txtComfirmPass" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Password="True" SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" 
                        TabIndex="3" Width="170px">
                    </dx:ASPxTextBox>
                    <asp:CompareValidator ID="CompareValidator1" runat="server" 
                        ControlToCompare="txtPass" ControlToValidate="txtComfirmPass" Display="None" 
                        ErrorMessage="Comfirm Password and Password does not match" 
                        SetFocusOnError="True"></asp:CompareValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel4" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Gender:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <table style="width:100%;">
                        <tr>
                            <td class="styleRegister2">
                                <dx:ASPxRadioButton ID="rdbMale" runat="server" Checked="True" 
                                    CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                                    GroupName="Gender" SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" 
                                    TabIndex="4" Text="Male">
                                </dx:ASPxRadioButton>
                            </td>
                            <td>
                                <dx:ASPxRadioButton ID="rdbFemale" runat="server" 
                                    CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                                    GroupName="Gender" SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" 
                                    Text="Female">
                                </dx:ASPxRadioButton>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel6" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Birthdate:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <dx:ASPxDateEdit ID="Birthdate" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" Spacing="0" 
                        SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="5">
                        <CalendarProperties>
                            <HeaderStyle Spacing="1px" />
                        </CalendarProperties>
                        <ValidationSettings CausesValidation="True" Display="None" 
                            ErrorText="Birthdate must less today" SetFocusOnError="True">
                            <RequiredField ErrorText="" />
                        </ValidationSettings>
                    </dx:ASPxDateEdit>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" 
                        ControlToValidate="Birthdate" Display="None" 
                        ErrorMessage="Birhdate is not blank!" SetFocusOnError="True"></asp:RequiredFieldValidator>
                    <asp:CustomValidator ID="CustomValidator1" runat="server" 
                        ControlToValidate="Birthdate" Display="None" 
                        ErrorMessage="Birthdate must less today." SetFocusOnError="True"></asp:CustomValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    <dx:ASPxLabel ID="ASPxLabel7" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        Text="Email:">
                    </dx:ASPxLabel>
                </td>
                <td>
                    <dx:ASPxTextBox ID="txtEmail" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="6" 
                        Width="170px">
                        <ValidationSettings>
                            <RegularExpression ErrorText="" />
                        </ValidationSettings>
                    </dx:ASPxTextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" 
                        ControlToValidate="txtEmail" Display="None" ErrorMessage="Email is not blank!" 
                        SetFocusOnError="True"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" 
                        ControlToValidate="txtEmail" Display="None" ErrorMessage="Email invalid" 
                        ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    &nbsp;</td>
                <td>
                    <dx:ASPxCaptcha ID="Capchar" runat="server" 
                        CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                        SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="7">
                        <LoadingPanelImage Url="~/App_Themes/DevEx/Editors/Loading.gif">
                        </LoadingPanelImage>
                        <RefreshButtonStyle>
                            <Paddings PaddingTop="4px" />
                        </RefreshButtonStyle>
                        <ValidationSettings>
                            <RequiredField ErrorText="Capchar is not blank!" IsRequired="True" />
                        </ValidationSettings>
                        <ChallengeImage BorderColor="#A8AAB4" BorderWidth="1" ForegroundColor="#CDAFE4">
                            <BackgroundImage ImageUrl="~/App_Themes/DevEx/Editors/caChallengeImageBack.png" />
                        </ChallengeImage>
                    </dx:ASPxCaptcha>
                </td>
            </tr>
            <tr>
                <td class="styleRegister">
                    &nbsp;</td>
                <td>
                    <table style="width:100%;">
                        <tr>
                            <td class="styleRegister3">
                                <dx:ASPxButton ID="btRegister" runat="server" 
                                    CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
                                    onclick="btRegister_Click" 
                                    SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="8" 
                                    Text="Register" ValidateInvisibleEditors="True" Width="19px">
                                    <ClientSideEvents Click="function(s, e) {
                                        Callback.PerformCallback();
                                        LoadingPanel.Show();
                                    }" />
                                </dx:ASPxButton>
                            </td>
                            <td>
                                <dx:ASPxButton ID="btReset" runat="server" AutoPostBack="False" 
                                    CausesValidation="False" CssFilePath="~/App_Themes/DevEx/{0}/styles.css" 
                                    CssPostfix="DevEx" onclick="btReset_Click" 
                                    SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="9" Text="Reset" 
                                    UseSubmitBehavior="False" Width="19px">
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
        </table>
    </asp:View>
    <asp:View ID="View2" runat="server">
        <dx:ASPxLabel ID="lbStatus" runat="server" 
            CssFilePath="~/App_Themes/DevEx/{0}/styles.css" CssPostfix="DevEx" 
            Font-Size="15px">
        </dx:ASPxLabel>
        <br />
        <dx:ASPxButton ID="btOk" runat="server" AutoPostBack="False" 
            CausesValidation="False" CssFilePath="~/App_Themes/DevEx/{0}/styles.css" 
            CssPostfix="DevEx" onclick="btOk_Click" 
            SpriteCssFilePath="~/App_Themes/DevEx/{0}/sprite.css" TabIndex="10" Text="Ok" 
            UseSubmitBehavior="False" Width="19px">
        </dx:ASPxButton>
    </asp:View>

</asp:MultiView>


